
#ifndef __GRAPHICS_GRAPHICSGL_HPP__
#define __GRAPHICS_GRAPHICSGL_HPP__

#include "IGraphics.hpp"
#include <GL/glew.h>
#include <GL/glfw.h>

namespace Graphics
{
	class GraphicsGL : public IGraphics
	{
	protected:
		RevEng::Math::Matrix4s m_MatView;
		RevEng::Math::Matrix4s m_MatWorld;
		RevEng::Math::Matrix4s m_MatProj;

		IVertexBuffer* m_pVerts;

	public:
		GraphicsGL();
		virtual ~GraphicsGL();

		virtual void BeginFrame(const RevEng::Math::Vector4s &Color);
		virtual void EndFrame();

		virtual void SetViewport(const RevEng::Math::Rect<RevEng::UInt32> &Area);
		virtual void SetTransform(RevEng::Enum TransType, const RevEng::Math::Matrix4s &In);
		virtual void SetLight(RevEng::UInt32 Index, const Light& Lgt);
		virtual void SetMaterial(const Material& Mat);
		virtual void SetVertices(IVertexBuffer* Buffer);
		virtual void SetIndices(IIndexBuffer* Buffer);

		virtual void Render(RevEng::Enum Primitive/*, RevEng::UInt32 Count*/);
		virtual bool DoEvents();
	};
}

#endif	//__GRAPHICS_GRAPHICSGL_HPP__
